make-pyuno-work-with-system-wide-module-install
authorDebian LibreOffice Maintainers <debian-openoffice@lists.debian.org>
Mon, 27 Aug 2012 16:47:58 +0000 (16:47 +0000)
committerRene Engelhard <rene@debian.org>
Mon, 27 Aug 2012 16:47:58 +0000 (16:47 +0000)
Gbp-Pq: Name make-pyuno-work-with-system-wide-module-install.diff

desktop/scripts/soffice.sh
pyuno/source/module/uno.py
scripting/source/pyprov/officehelper.py

index 97a2be913f13f867dc65c10a8a96c0c1319646a6..23ef132ef65f71157a998d0d889b00ea90d2e4b5 100755 (executable)
@@ -129,6 +129,9 @@ if echo "$checks" | grep -q "cc" ; then
     exit 1;
 fi
 
+PYTHONPATH=$sd_prog${PYTHONPATH+:$PYTHONPATH}
+export PYTHONPATH
+
 case "`uname -s`" in
 NetBSD|OpenBSD|FreeBSD|DragonFly)
 # this is a temporary hack until we can live with the default search paths
index e82d2fee0cb4247dee605e6b936fa4df1e4d07b4..9b1e3616449827ec083ffcbdd4abc41b400692d1 100644 (file)
 # for a copy of the LGPLv3 License.
 #
 #*************************************************************************
+import os
 import sys
 
+sys.path.append('/usr/lib/libreoffice/program')
+if getattr(os.environ, 'URE_BOOTSTRAP', None) is None:
+     os.environ['URE_BOOTSTRAP'] = "vnd.sun.star.pathname:/usr/lib/libreoffice/program/fundamentalrc"
 import pyuno
 
 try:
index 84b7cce955a2db63c69e1a4bb1b01e842d88d8a3..3b6628921a7174364fdb98f20f3a6a708a959a1c 100755 (executable)
@@ -53,7 +53,7 @@ def bootstrap():
         if "UNO_PATH" in os.environ:
             sOffice = os.environ["UNO_PATH"]
         else:
-            sOffice = "" # lets hope for the best
+            sOffice = "/usr/lib/libreoffice/program"
         sOffice = os.path.join(sOffice, "soffice")
         if platform.startswith("win"): 
             sOffice += ".exe"